//
//  BCCoinTypeButton.m
//  GSBlockChain
//
//  Created by guoshikeji_a on 2018/11/15.
//  Copyright © 2018年 guoshikeji. All rights reserved.
//

#import "BCRechargeCoinTypeButton.h"

@interface BCRechargeCoinTypeButton ()

@property (nonatomic, strong) UILabel *coinLabel;

@property (nonatomic, strong) UILabel *captionLabel;

@end

@implementation BCRechargeCoinTypeButton

- (instancetype)init
{
    self = [super init];
    if (self) {
        self.backgroundColor = [UIColor qmui_colorWithHexString:@"#F6F5FA"];
        self.layer.cornerRadius = 2;
        [self setupSubviews];
    }
    return self;
}

- (void)setupSubviews {
    self.coinLabel = [UILabel new];
    [self addSubview:self.coinLabel];
    self.coinLabel.textColor = [UIColor qmui_colorWithHexString:@"#666666"];
    self.coinLabel.font = [UIFont systemFontOfSize:16 weight:UIFontWeightMedium];
    [self.coinLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.mas_equalTo(self).offset(13.0);
        make.centerY.mas_equalTo(self);
    }];
    //
    self.captionLabel = [UILabel new];
    self.captionLabel.textColor = [UIColor qmui_colorWithHexString:@"#999999"];
    self.captionLabel.font = [UIFont systemFontOfSize:13 weight:UIFontWeightMedium];
    [self addSubview:self.captionLabel];
    [self.captionLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerY.mas_equalTo(self);
        make.right.mas_equalTo(self).offset(-13.0);
    }];
//    self.captionLabel.text = BCLocalizedKey(@"wallet_recharge_choose_coin_Type");
}


- (void)setCoinType:(NSString *)coinType {
    _coinType = coinType;
    //
    self.coinLabel.text = coinType;
}
- (void)setCaption:(NSString *)caption {
    _caption = caption;
    //
    self.captionLabel.text = caption;
}


@end
